<template>
  <div class="star">
    <i v-for="i in total"
       :key="i"
       :class="`iconfont icon-wjx0${i > score ? 2 : 1}`"/>
  </div>
</template>

<script lang="ts"
        setup>
withDefaults(defineProps<{
  score: number,
  total?: number
}>(), {
  total: 5
})
</script>

<style lang="less"
       scoped>
.star {
  display: flex;
  font-size: 16px;
  color: #ff9240;
}
</style>